<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <title>订单详情页</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="format-detection" content="telephone=no">
    <link rel="stylesheet" href="resources/layui/css/layui.css" media="all" />
    <link rel="stylesheet" href="resources/css/public.css" media="all" />
</head>
<body class="childrenBody">
<form class="layui-form" style="width:100%;" id="dataFrm">
    <div class="layui-form-item layui-row layui-col-xs12" >
        <label class="layui-form-label">订单编号:</label>
        <div class="layui-input-block ">
            <input type="text" class="layui-input num" name="num" lay-verify="required" readonly="readonly" style="width: 200px" >
        </div>
    </div>
    <div class="layui-form-item layui-row layui-col-xs12">
        <label class="layui-form-label">用户姓名:</label>
        <div class="layui-input-block">
            <input type="text" class="layui-input name" name="name" lay-verify="required" readonly="readonly" style="width: 200px">
        </div>
    </div>
<!--    <div class="layui-form-item layui-row layui-col-xs12">-->
<!--        <label class="layui-form-label">车牌号:</label>-->
<!--        <div class="layui-input-block">-->
<!--            <input type="hidden" id="serviceIdHiden1">-->
<!--            <input type="text" class="layui-input perCarPlatenum" name="perCarPlatenum" lay-verify="required" readonly="readonly" style="width: 200px" >-->
<!--        </div>-->
<!--    </div>-->
    <div class="layui-form-item layui-row layui-col-xs12">
        <label class="layui-form-label">预约开始时间:</label>
        <div class="layui-input-block">
            <input type="text" class="layui-input startTime" name="startTime" lay-verify="required"  readonly="readonly" style="width: 200px">
        </div>
    </div>
    <div class="layui-form-item layui-row layui-col-xs12">
        <label class="layui-form-label">预约结束时间:</label>
        <div class="layui-input-block">
            <input type="text" class="layui-input endTime" name="endTime" lay-verify="required" readonly="readonly" style="width: 200px">
        </div>
    </div>
<!--    <div class="layui-form-item layui-row layui-col-xs12">-->
<!--        <label class="layui-form-label">单价（元/时）:</label>-->
<!--        <div class="layui-input-block">-->
<!--            <input type="hidden" id="serviceIdHiden3"></input>-->
<!--            <input type="hidden" id="serviceIdHiden2"></input>-->
<!--            <input type="text" class="layui-input  unvalent" id="unvalent" name="unvalent" lay-verify="required" readonly="readonly" style="width: 200px">-->
<!--        </div>-->
<!--    </div>-->
    <div class="layui-form-item layui-row layui-col-xs12">
        <label class="layui-form-label">代金券（元）:</label>
        <div class="layui-input-block">
            <input type="text" class="layui-input cash" name="cash" lay-verify="required"  readonly="readonly" style="width: 200px">
        </div>
    </div>
    <div class="layui-form-item layui-row layui-col-xs12">
        <label class="layui-form-label">总价（元）:</label>
        <div class="layui-input-block">
            <input type="text" class="layui-input money" name="money" lay-verify="required"  readonly="readonly" style="width: 200px">
        </div>
    </div>
    <div class="layui-form-item layui-row layui-col-xs12">
        <label class="layui-form-label">车位位置:</label>
        <div class="layui-input-block " >
            <input type="text" class="layui-input location " name="location" lay-verify="required"  readonly="readonly" style="width: 200px">
        </div>
    </div>
</form>
<script type="text/javascript" src="resources/layui/layui.js"></script>
<script th:inline="none">
    layui.use(['form','layer','laydate','table','laytpl','upload'],function() {
        var form = layui.form
        layer = parent.layer === undefined ? layui.layer : top.layer,
            $ = layui.jquery,
            laydate = layui.laydate,
            laytpl = layui.laytpl,
            table = layui.table,
            upload=layui.upload;


        var id=$("#serviceIdHiden2").val();
        var mark=$("#serviceIdHiden3").val();
        if (mark==1){
            $.ajax({
                url: "findMuPrice.do",
                data: {mu_id:id},
                type: "GET",
                dataType: "json",
                success: function (res) {
                    $(".unvalent").val(res);
                }
            })
        }else if (mark==2) {
            $.ajax({
                url: "findStallPrice.do",
                data: {pu_id:id},
                type: "GET",
                dataType: "json",
                success: function (res) {
                    $(".unvalent").val(res);
                }
            })
        }

        var id=$("#serviceIdHiden1").val();
        $.ajax({
            url: "findPlatenum.do",
            data: {pu_id:id},
            type: "GET",
            dataType: "json",
            success: function (res) {
                console.log(res)
                $(".perCarPlatenum").val(res);
            }
        })


        });

</script>
</body>
</html>